﻿@model WebUI.Models.QizSession
<div id="anchorslist">
    <div>
        快速定位:<br />
        <a href="#Subject_@(Model.QizSubject.ID)" title="@Model.QizSubject.Title">@Model.QizSubject.Title</a><br />
        @foreach (var item in Model.QizSubject.SubQizSubjects.OrderByDescending(v => v.SortIdx))
        {
            <a  href="#Subject_@(item.ID)" title="@item.Title" >@item.Title</a><br />
        }
    </div>
</div>
<script type="text/javascript">
    $(function () {
        $("#anchorslist a").click(
                function () {
                    ((window.opera) ? (document.compatMode == "CSS1Compat" ? $('html') : $('body')) : $('html,body')).animate({ scrollTop: $($.attr(this, 'href')).offset().top - 3 }, 1000);
                    return false;
                }
            );
    });
</script>
